package com.fdq.dianping.util;

public class Constants {
    //用户session中保存验证码的键
    public static final String User_Code = "code:";
    //用户随机昵称前缀
    public static final String User_NickName_Prefix="user_";
    //用户随机昵称长度
    public static final int User_NickName_Num = 10;

    //用户在session中的键
    public static final String User = "user:";

    //用户存储在redis的token的前缀
    public static final String Token_Prefix="token:";

    //用户在redis中信息的有效时间
    public static final int User_Token_TTL = 30;

    //商户id前缀
    public static final String Shop_Prefix="shop:";

    //商户信息在redis有效时间
    public static final Long Shop_TTL = 30L;

    //空白商户信息有效时间
    public static final int Shop_Null_TTL = 2;

    //商户互斥锁前缀
    public static final String Shop_Mutex_prefix = "shop_mutex:";

    //商户互斥占位符（信号量？）
    public static final String Shop_Mutex = "isMutex";

    //未获取到锁的线程休眠时间基准
    public static final long Shop_Mutex_TTL = 50;

    //商户种类id前缀
    public static final String Shop_Type = "shop_type";

    //redis中空白值的有效时间
    public static final int Cache_Null_TTL = 2;

    //优惠券订单id在redis中的键前缀
    public static final String VoucherOrder_Prefix = "voucherOrder:";

    //分页大小
    public static final int Page_Size = 10;

    //商户按geo类型存储在redis中的key
    public static final String Shop_Geo_Key = "shop:geo:type";

    //商户按评分类型存储在redis中的key
    public static final String Shop_Score_Key = "shop:score:type";

    //按评分查看商户更新的锁前缀
    public static final String Shop_Score_Mutex_Prefix = "shop:score:mutex:";

    //点评点赞过的成员集合前缀
    public static final String Blog_Like = "blog:liked:";

    //点评评论点赞
    public static final String BlogComment_Like= "blogComment:liked:";

    //查询附近商户的距离
    public static final int Shop_distance = 300000000;

    //共同关注在redis中的键前缀
    public static final String Follow_Common = "follow:common:";

    //用户在redis中的收件箱键的前缀
    public static final String Feed_Prefix = "feed:";

    //分页查询收件箱时一次查多少
    public static final int Feed_page = 2;

    //秒杀优惠券库存在redis中的前缀
    public static final String SeckillVoucher_Stock = "seckillVoucher:stock:";

    //秒杀优惠券库存redis中的ttl
    public static final Long SeckillVoucher_Stock_TTL = 30L;
}
